package com.dh.blog.vo;

import java.io.Serializable;

import javax.validation.constraints.NotNull;

import org.hibernate.validator.constraints.NotBlank;

import com.ewei.web.common.validator.CascadeGroup;
import com.ewei.web.common.validator.SaveGroup;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
/**
 * 分类VO
 * @author David
 *
 */
@JsonInclude(Include.NON_EMPTY)
public class ClassifyVo implements Serializable{
	/**
	 * serialVersionUID
	 */
	private static final long serialVersionUID = -5662358140644870358L;
	@NotNull(message="{classify.id.not.null}",groups={CascadeGroup.class})
	private Integer id;
	@NotBlank(message="{classify.not.blank}",groups={SaveGroup.class})
	private String name;
	@JsonIgnore
	private String blogId;
	private int articleNum = 0;
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public int getArticleNum() {
		return articleNum;
	}
	public void setArticleNum(int articleNum) {
		this.articleNum = articleNum;
	}
	public String getBlogId() {
		return blogId;
	}
	public void setBlogId(String blogId) {
		this.blogId = blogId;
	}
	
}
